package com.qfedu.service;

import com.github.pagehelper.PageInfo;
import com.qfedu.entity.AdinmEntity;
import com.qfedu.entity.RolesEntity;
import com.qfedu.kit.StringUtil;
import com.qfedu.util.Page;

import java.util.List;
import java.util.Set;

public interface AdminService {

    public boolean insertuser(String username, String password);


    public AdinmEntity queryuser(String username, String password);

    public AdinmEntity queryuserbyname(String username);

    //根据用户查询当前角色
    public Set<String> queryRoleByusername(String username);

    //跳转超级管理员界面并做分页
    public Page mapperList(AdinmEntity ad);

    //跳转超级管理员界面并做角色分页
    public Page mapperListrole(RolesEntity ro);

    //跳转超级管理员界面并做分页
    public AdinmEntity adminList(AdinmEntity ad);


    //编辑admi界面
    public boolean adminedit(AdinmEntity ad);

    //查询所有角色
    public List<RolesEntity> queryroles();

    //删除某管理员
    public boolean deletebyid(int aid);

    //启用某管理员
    public boolean qiyongbyid(int aid);

    //删除所有
    public boolean deAll(String ids);

    //添加管理员提交
    public boolean tiaoadmin(AdinmEntity ad);

    //根据角色id查询
    public RolesEntity selrole(RolesEntity ro);

    //角色修改
    public boolean editrole(RolesEntity ro);

    //添加角色
    public boolean addroleti(RolesEntity ro);

    //删除角色
    public boolean deleterole(int rid);

    //编辑管理员提交
    public boolean sendadmin(AdinmEntity ad);
}
